package com.heima.domain.po;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springdoc.core.annotations.ParameterObject;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 健康数据表
 * </p>
 *
 * @author author
 * @since 2025-07-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("health_data")
public class HealthData implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 步数
     */
    private Long steps;

    /**
     * 体重(kg)
     */
    private Double weight;

    /**
     * 收缩压（高压）
     */
    private Integer highPressure;

    /**
     * 舒张压（低压）
     */
    private Integer lowPressure;

    /**
     * 心率(次/分)
     */
    private Integer heartRate;

    /**
     * 血糖(mmol/l)
     */
    private Double bloodSugar;

    /**
     * 睡眠时长(小时)
     */
    private Double sleepDuration;

    /**
     * 创建时间
     */
//    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * 修改时间
     */
//    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    /**
     * 用户id
     */
    private Long userId;


}
